#include "PD3DFileX.h"

PD3DFileX::PD3DFileX(char* fileName)
{ 
	 LPD3DXFILE file = NULL;
    if (FAILED(D3DXFileCreate(&file)))
		throw new string("CreateXFile::D3DXFileCreate()");
	LPD3DXFILEENUMOBJECT enumObject = NULL;
    if (FAILED(file->CreateEnumObject(fileName, DXFILELOAD_FROMFILE, &enumObject)))
        throw new string("ProcessObjects::D3DXFileCreate()");
	
}



LPD3DXFILEENUMOBJECT PD3DFileX::GetEnumObject()
{
	return enumObject;
}
PD3DFileX::~PD3DFileX(void)
{
	delete[] info;
	delete[] triangles;
	delete[] tiles;
	enumObject->Release();
}
